home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 12 / Cream of the Crop 12 (Part II) / Cream of the Crop 12 (Part II).iso / BBS / ANIPRMT1.ZIP / PSE_EXEC.ZIP / PSE-XMPL.SRC < prev   
Encoding:
Text File  |  1996-03-08  |  3.3 KB  |  97 lines

  1.  
  2. ###### PSE-XMPL.SRC ########################################################
  3.  
  4. ###    Animated pause prompt example source code.    1996 SPORT!ware    ####
  5.   #   Contact U. CraZy Diamond@SPORT! on DoveNet or DiamondNet or call   #
  6.   #             The Serial Port BBS (807) 547-2134                       #
  7.    #                                                                   #
  8.      #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~#
  9.  #~~~~            To install, compile with BAJA.EXE and              ~~~~#
  10.  #             edit line 563 of SBBS\CTRL\TEXT.DAT to read:              #
  11.  #                                                                       #
  12.  #      "@EXEC:PSE-XMPL@"       563 Pause                                #
  13.  #                                                                       #
  14.  #  *It is recomended that you rename the file to PAUSExx where "xx" is  #
  15.  #   a two digit number.  This will allow it to work with the included   #
  16.  #   pause prompt previewer, PAUSECHK.BIN                                #
  17.  #_____                                                             _____#
  18.      ##=============================================================##
  19.  
  20. int c             # Integer variable to count loops
  21.  
  22.     ##--[ This will hide the cursor from ansi terminals
  23. print "nks  "
  24.  
  25.     ##--[ Top of loop
  26. :PAUSE_LP
  27.  
  28.     ##--[ This part watches for a keypress while allowing loop execute
  29. inkey
  30. if_true
  31.     print "[>"
  32.     compare_key N
  33.     if_true
  34.         setstr "N"
  35.     else
  36.         setstr "\r"
  37.         end_if
  38.     ungetstr
  39.     return
  40.     end_if
  41.  
  42.     ##--[ This is the prompt displayed to the user
  43. switch c
  44.     case 0
  45.         print "[   hy■b∙∙∙∙∙∙wHit a keyb∙∙∙∙∙∙∙nku"
  46.         end_case
  47.     case 1
  48.         print "[   hb∙∙y■■b∙∙∙wHit a keyb∙∙∙∙∙∙∙nku"
  49.         end_case
  50.     case 2
  51.         print "[   hb∙∙∙∙y■■b∙wHit a keyb∙∙∙∙∙∙∙nku"
  52.         end_case
  53.     case 3
  54.         print "[   hb∙∙∙∙∙∙y■wHit a keyy■b∙∙∙∙∙∙nku"
  55.         end_case
  56.     case 4
  57.         print "[   hb∙∙∙∙∙∙∙wHit a keyy■■b∙∙∙∙∙nku"
  58.         end_case
  59.     case 5
  60.         print "[   hb∙∙∙∙∙∙∙wHit a keyb∙∙y■■b∙∙∙nku"
  61.         end_case
  62.     case 6
  63.         print "[   hb∙∙∙∙∙∙∙wHit a keyb∙∙∙∙y■■b∙nku"
  64.         end_case
  65.     case 7
  66.         print "[   hb∙∙∙∙∙∙∙wHit a keyb∙∙∙∙∙∙y■nku"
  67.         end_case
  68.  
  69.     ##--[ The "default" case should never be displayed and is here only
  70.     #      as a safety feature.  If it DOES display then the int c var
  71.     #      has somejow gotten messed up. ie: does not fall within the
  72.     #      number of cases specified
  73.     default
  74.         print "[   hb{wHit a keyb}nku"
  75.         end_case
  76.     end_switch
  77.  
  78.     ##--[ Set this number to corespond with the number of cases switched
  79.     #   (See comment above DEFAULT)
  80. compare c 7
  81. if_equal
  82.     set c 0
  83. else
  84.     add c 1
  85.     end_if
  86.  
  87.     ##--[ MSWAIT gives up timeslices so shouldn't affect other nodes
  88.     #     that are running on the same machine.  Experiment with it but
  89.     #     it's better to add CASE's rather than increase this number to
  90.     #     slow down the animation.  A lower number here makes a keypress
  91.     #     appear almost instantanious
  92. mswait 20
  93.  
  94. goto PAUSE_LP
  95.  
  96.     ##------------------========={ EOT }=========------------------##
  97.